<?php include_once 'tie_header.php';?>
<!--主体内容-->
<div class="main">
	<?php include_once 'tie_left.php';?>
	
	<div class="right_c">
    	<div class="tie_title">
        	<ul>
            <li class="on"><a href="index.php?mod=tie">最新招贴</a></li>
            <li><a href="index.php?mod=tie&code=myfav">我关注的人的招贴</a></li>
            </ul>
        </div>
        <div class="tie_title_type">
		<?php foreach ( $tie_category as $key => $val ){ ?>
        	<a href="#" rel="cate_<?php echo $key;?>" <?php echo ( $key==0 ) ? 'class="this"' : '';?>><?php echo $val;?></a> 
        <?php } ?>
		</div>
		

	<?php foreach ( $tie_category as $key => $val ){ ?>
	<div id="tie_cate_<?php echo $key;?>" <?php echo ( $key>0 ) ? 'style="display:none;"' : '';?>>
	    <?php foreach( $ties[$val] as $tie ){ ?>
		<dl class="tie_list">
        	<dt><a href="###"><img src="<?php echo $tie['face'];?>" /></a></dt>
            <dd>
            <h2><a href="index.php?mod=<?php echo $tie['username'];?>"><?php echo $tie['nickname'];?> ：</a></h2>
            <h4>
            <img src="upload/tie/<?php echo $tie['pic'];?>" />
			<?php echo $tie['content'];?>
            </h4>
            <div class="float_both"></div>
            <span><?php echo date("Y-m-d H:i:s",$tie['addtime']);?> 发布</span>
            </dd>
        </dl>
        <div class="float_both"></div>
		<?php } ?>
	</div>
	<?php } ?>

        
	</div>
<div class="float_both"></div>
</div>
<script type="text/javascript">
$(function(){
	$(".tie_title_type a").click(function(){
		$(".tie_title_type a").removeClass("this");
		$(this).addClass("this");	
		$("div[id^='tie_cate_']").slideUp();
		$("#tie_"+$(this).attr("rel")).slideDown();
	});
});
</script>
<!--底部-->
<?php include_once 'footer.php';?>
